export default [
  {
    path: "/",
    redirect: "/home"
  },
  { //首页
    name: "Home",
    path: "home",
    meta: {
      title: "统计",
      icon: "el-icon-s-home"
    },
    component: () => import("@/views/home/index.vue")
  },
  { //角色管理
    name: "role",
    path: "role",
    meta: {
      title: "角色管理",
      icon: "el-icon-s-custom"
    },
    component: () => import("@/views/roles/index.vue")
  },
  { //组织管理
    name: "department",
    path: "department",
    meta: {
      title: "组织",
      icon: "el-icon-s-platform"
    },
    component: () => import("@/views/department/index.vue")
  },
  { //员工管理
    name: "employee",
    path: "employee",
    meta: {
      title: "员工",
      icon: "el-icon-user-solid"
    },
    children: [
      { //员工的列表
        name: "employeeHome",
        path: "/",
        component: () => import("@/views/employee/children/employeeHome.vue"),
        meta: {
          title: "员工列表"
        }
      },
      { //员工详情
        name: "detail",
        path: "detail",
        component: () => import("@/views/employee/children/employeeDetail.vue"),
        meta: {
          title: "员工详情"
        }
      }
    ],
    component: () => import("@/views/employee/index.vue")
  },
  { //审批管理
    name: "approval",
    path: "approval",
    meta: {
      title: "审批",
      icon: "el-icon-s-order"
    },
    component: () => import("@/views/approval/index.vue")
  },
  { //审批详情
    name: "approvaldetail",
    path: "approvaldetail/:approvalId",
    meta: {
      title: "审批详情",
      icon: "el-icon-s-order"
    },
    component: () => import("@/views/approval/child/approvalDetail.vue")
  },
  { //权限管理
    path: "permission",
    name: "permission",
    meta: {
      title: "权限",
      icon: "el-icon-s-claim"
    },
    component: () => import("@/views/permission/index.vue")
  },
  { //考勤模块
    name: "attendance",
    path: "attendance",
    meta: {
      title: "考勤",
      icon: "el-icon-s-data"
    },
    component: () => import("@/views/attendance/index.vue")
  },
  { //薪资管理
    name: "salary",
    path: "salary",
    meta: {
      title: "薪资",
      icon: "el-icon-s-finance"
    },
    component: () => import("@/views/salary/index.vue")
  },
  { //社保管理
    name: "social",
    path: "social",
    meta: {
      title: "社保",
      icon: "el-icon-s-custom"
    },
    component: () => import("@/views/social/index.vue")
  },
  { //图表管理模块
    name: "chart",
    path: "chart",
    meta: {
      title: "图表管理",
      icon: "el-icon-s-finance"
    },
    component: () => import("@/views/chart/index.vue")
  }
]